package cloud.misiro.spring.beans.factory.config;

import cloud.misiro.spring.beans.BeansException;
import cloud.misiro.spring.beans.factory.PropertyValues;

public interface InstantiationAwareBeanPostProcessor extends BeanPostProcessor {
    Object postProcessBeforeInstantiation(Class<?> beanClass, String beanName) throws BeansException;

    boolean postProcessAfterInstantiation(Object bean, String beanName) throws BeansException;

    PropertyValues postProcessPropertyValues(PropertyValues pvs, Object bean, String beanName) throws BeansException;

    default Object getEarlyBeanReference(Object bean,String beanName) throws BeansException {
        return bean;
    }
}
